package org.dwell.vertx3.server;

import io.vertx.core.*;

/**
 * Created by Emily on 16/1/13.
 */
public class Launcher implements Verticle {
    private Vertx vertx;

    public static void main(String[] args) {
        //org.apache.log4j.BasicConfigurator.configure();
        Runner.runExample(Launcher.class);
    }

    @Override
    public Vertx getVertx() {
        return vertx;
    }

    @Override
    public void init(Vertx vertx, Context context) {
        this.vertx = vertx;
    }

    @Override
    public void start(Future<Void> future) throws Exception {
        vertx.deployVerticle(new ChatVerticle());
        vertx.deployVerticle(new EventVerticle());
        //vertx.deployVerticle(new Logger());
    }

    @Override
    public void stop(Future<Void> future) throws Exception {

    }
}
